﻿using System.Collections.Generic;
using ZhiKeDuoServer.Model;
using IDAL;

namespace DAL
{
    public class InGoodsService : Base<InGoods>
    {
 

        public bool Delete(string Code)
        {
            return DB.Client.Deleteable<ZhiKeDuoServer.Model.InGoods>().Where(t => t.PCode == Code).ExecuteCommandHasChange();
        }

  


        public bool Exists(string Code)
        {
            return DB.Client.Queryable<ZhiKeDuoServer.Model.InGoods>().Where(t => t.PCode == Code).Any();
        }

   



        public InGoods GetModel(string Code)
        {
            return DB.Client.Queryable<ZhiKeDuoServer.Model.InGoods>().Where(t => t.PCode == Code).First();
        }



    }
}